package micro86.operation;

import micro86.engine.Memory;
import micro86.engine.State;

import java.util.List;

/**
 * (c) Kate Luzhevskaya 2013
 */
public class Print implements IOperation{
    List<IOperation> list;

    public Print (List<IOperation> list) {
        this.list = list;
    }

    @Override
    public void execute(State state, Memory memory) throws IOperationException{
        for (IOperation operation : list) {
            operation.execute(state, memory);
        }
        state.incIP();
    }

}
